import { WeaTools } from 'ecCom';


//获取我的合同顶部条件
export const getConditionTop = (params={}) => {
    return WeaTools.callApi('/api/contract/home/getConditionFieldsAndSelect', 'GET', params);
}

//获取合同类型
export const getContractType = (params={}) => {
    return WeaTools.callApi('/api/contract/tree/getTreeData', 'GET', params);
}
//获取合同统计相关
export const getLedgerRpData = (params={}) => {
    return WeaTools.callApi(`/api/contract/total/${params.page}`, 'GET', params);
}

export const getInitInfoFromCube = (params={}) => {
    return WeaTools.callApi('/api/cube/search/init?guid=search', 'GET', params);
}

export const getRightMenuFromCustom = (params={}) => {
    return WeaTools.callApi('/api/contract/home/getRightMenu', 'GET', params);
}

export const getConditionFromCube = (params={}) => {
    return WeaTools.callApi('/api/cube/search/condition?guid=search', 'GET', params);
}

export const deleteData = (params={}) => {
    return WeaTools.callApi('/api/cube/expand/deleteData?guid=search&operate=DeleteAction', 'GET', params);
}

export const doAttention = (params={}) => {
    return WeaTools.callApi('/api/contract/home/store', 'GET', params);
}

export const getAttentions = (params={}) => {
    return WeaTools.callApi('/api/contract/home/getStore', 'GET', params);
}

export const getCardTabs = (params={}) => {
    return WeaTools.callApi('/api/contract/card/tab', 'GET', params);
}

export const getAgreedBill = (params={}) => {
    return WeaTools.callApi('/api/contract/tab/getPlanListByConsId', 'GET', params);
}

export const getPayListByPlanId = (params={}) => {
    return WeaTools.callApi('/api/contract/tab/getPayListByPlanId', 'GET', params);
}

export const getTicketListByConsId = (params={}) => {
    return WeaTools.callApi('/api/contract/tab/getTicketListByConsId', 'GET', params);
}

export const getActualBill = (params={}) => {
    return WeaTools.callApi('/api/contract/tab/getPayListByConsId', 'GET', params);
}

export const getWorkflow = (params={}) => {
    return WeaTools.callApi('/api/contract/workflow/getWorkflow', 'GET', params);
}

export const updateGroup = (params={}) => {
    return WeaTools.callApi('/api/contract/workflow/updateGroup', 'GET', params);
}

export const getListFromCube = (params={}) => {  
    return WeaTools.callApi('/api/cube/search/getList?guid=search', 'GET', params);
}


export const getChangeList = (params={}) => {  
    return WeaTools.callApi('/api/contract/tab/getChangeListByConsId', 'GET', params);
}

export const getModeInfo = (params={}) => {  
    return WeaTools.callApi('/api/contract/mode/getModeInfo', 'GET', params);
}

export const getDynamic = (params={}) =>{
    return WeaTools.callApi('/api/contract/tab/getDynamic', 'GET', params);
}

export const getRightInfo = (params={}) =>{
    return WeaTools.callApi('/api/contract/mode/getRightInfo', 'GET', params);
}

export const getReportInfo = (params={}) =>{
    return WeaTools.callApi(`/api/contract/report/${params.page}`, 'GET', params);
}

export const sendPays = (params={}) =>{
    return WeaTools.callApi('/api/contract/card/sendPays', 'GET', params);
}
